<template>
	<view class="" >
		<view class="time_day">
			<view class="title border weight">
				营业时间
			</view>
			<view class="title flex">
				<view class="icon">
					<u-icon name="clock" color="#9f2b45"></u-icon>
				</view>
				<view class="">
					<view class="text">
					     {{data.isBusiness?'营业中':'休息中'}}	
					</view>
					<view class="text"  >
						<view class="" v-for="(item,index) in dayTime" :key="index" >
							{{item}}
						</view>
						
					</view>
				</view>
			</view>
		</view>
		<view class="time_day">
			<view class="title border weight">
				资质证明
			</view>
			<view class="title flex">
				<view class="icon">
					<u-icon name="file-text" color="#9f2b45"></u-icon>
				</view>
				<view class="text flex between items" style="width: 100%;" @click="Look()">
					<view class="flex items" style="justify-content: center;">
						营业执照
					</view>
					<view class="">
						<u-icon name="arrow-right"></u-icon>
					</view>
				</view>
			</view>
		</view>
		<view class="liability">
			<view class="liability_title" >
				<u-line length="70"></u-line> <text style="margin: 0 30rpx;">免责声明</text>  <u-line length="70" ></u-line>
			</view>
			<view class="">
				以上信息来源于商家上传内容,平台仅提供展示服务,商家需保证信息真实有效。如与实际不符或有疑问,请联系平台客服
			</view>
		</view>
	</view>

</template>

<script>
	import {
		yxSystemMerchantStore
	} from "@/api/business"
	export default {
		data() {
			return {
				list: [{
					name: '全部'
				}],
				dayTime:[],
				images: [],
				data: {}
			}
		},
		mounted() {
			this.getInfo()
		},
		methods: {
			Look() {
				uni.previewImage({
					current: 0,
					urls: [this.data.businessLicense],
				});
			},

			//获取详情
			getInfo() {
				let data = this.$yroute.query
				console.log('data', this.$yroute)
				yxSystemMerchantStore(data).then(res => {
					this.data = res.data.content[0]
					this.dayTime=res.data.content[0].dayTime.split(".")

					this.$forceUpdate()
				})
			},
		}
	}
</script>


<style scoped lang="less">
	.liability{
		// position: fixed;
		// bottom: 0rpx;
		font-size: 20rpx;
		padding: 30rpx 15rpx;
		color: #c3c3c3;
		.liability_title{
			text-align: center;
			display: flex;
			justify-content: center;
			align-items: center;
			padding: 20rpx 0;
		}
		
	}
	.flex {
		display: flex;
	}

	.items {
		align-items: center;
	}

	.between {
		justify-content: space-between;
	}

	.border {
		border-bottom: #F7F9FB solid 1rpx;
	}

	.title {
		width: 95%;
		margin: auto;
		padding: 25rpx 0;
		font-size: 26rpx;
	}

	.weight {
		font-weight: 500;
	}

	.text {
		padding: 10rpx 0;
		font-size: 26rpx;
		color: #363636;
	}

	.time_day {
		background-color: #fff;
		width: 100%;
		margin-bottom: 25rpx;
	}

	.icon {
		height: calc( 16px + 28rpx );
		background-color:rgba(235,90,32,0.2);
		border-radius: 50%;
		padding: 14rpx 14rpx;
		margin-right: 20rpx;
	}
</style>